#pragma once

#include <mythread.hxx>

class Task;
class FileLog;
class TaskManager;



class Watcher : public Thread
{
public:
	Watcher(TaskManager* taskManager, Task* seed = NULL, FileLog* filelog = NULL);
	~Watcher();

	void Shutdown(void);

protected:
	virtual void Execute(Thread::Arg);

private:
	void DisplayMsg(string msg, int level);

	TaskManager* taskManager;
	Task* seed;

	bool isShutdownRequested;
	FileLog* _filelog;

};